repo: Fix bare-user file loads
authorColin Walters <walters@verbum.org>
Mon, 12 Jan 2015 17:39:57 +0000 (12:39 -0500)
committerColin Walters <walters@verbum.org>
Mon, 12 Jan 2015 17:43:33 +0000 (12:43 -0500)
commit019635d9c2f89dac56fb40e3df2752ef81fedff3
treee981f9fc21d2600476d055c8568533c5d7040542
parent25a590950095e501c1f3a56be91d7cb97794cb5a
repo: Fix bare-user file loads

Regression from 86764dbf007fca1e42aacb830e3c1911b198be6e

This function is kind of fiendish now that we have 3 cases, each of
which want to be optimized somewhat to only load what's necessary
(e.g. don't open the file if we don't have an output for stream
requested).

Clean things up so that BARE_USER and BARE are separate conditionals
that share as much as possible, and fix the bug that asserted we
were in BARE mode.

I tested this by running test-basic-user.sh by hand.
src/libostree/ostree-repo.c